#include<stdio.h>
int main()
{

	int num = 1;
	
	
	for (num = 1;num<2000 ; num++)
	{
		int num1 = num + 100;
		int num2 = num + 268;
		if (f(num1) == num1 && f(num2) == num2)
		{
			printf("%d ", num);
			
		}
	}
	return 0;

}
   int f(int x)
{
	int t = 1;
	int sum = 0;
	while (t <= x / 2)
	{
		if (t * t == x)
		{
			sum = x;
		}
		
		
		t++;
	}
         return sum;
}